package com.lucan.tracking.plugin

import com.android.build.gradle.AppExtension
import org.gradle.api.Plugin
import org.gradle.api.Project

/**
 * @author qihailong
 * @date 2018/7/13 下午4:28
 * @description TODO
 */

class TrackPlugin implements Plugin<Project> {

    @Override
    void apply(Project project) {
        System.out.println("------------------开始----------------------")
        System.out.println("这是我们的自定义插件!")
        System.out.println("------------------结束----------------------")
        def android = project.extensions.getByType(AppExtension)
        android.registerTransform(new TrackTransform())
    }
}

